//
//  StoreCell.m
//  OrderFood
//
//  Created by xiaofang wang on 2018/10/24.
//  Copyright © 2018年 zhiyuan. All rights reserved.
//

#import "StoreCell.h"
@interface StoreCell()
//@property(nonatomic,strong)UIImageView *storeImgView;
//@property(nonatomic,strong)UILabel *storeAddressLb;
//@property(nonatomic,strong)UILabel *allIncomeLb;
//@property(nonatomic,strong)UILabel *storeNameLb;
//@property(nonatomic,strong)UIButton *actionBtn;
@end
@implementation StoreCell

-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        [self setupUI];
    }
    return self;
}

-(void)setupUI{
    self.storeImgView = [[UIImageView alloc] initWithFrame:CGRectMake(15, 15, 100, 100)];
    self.storeImgView.backgroundColor = BLACKCOLOR;
    [self.contentView addSubview:self.storeImgView];
    self.storeAddressLb = [[UILabel alloc] initWithFrame:CGRectMake(self.storeImgView.mh_right+15, self.storeImgView.mh_top+5, SCREEN_WIDTH - self.storeImgView.mh_right-30 , 30)];
    self.storeAddressLb.font = FONT(16);
    self.storeAddressLb.text = @"杭州东站店";
    [self.contentView addSubview:self.storeAddressLb];
    
    UILabel *leftAllIncomeLb = [[UILabel alloc] initWithFrame:CGRectMake(self.storeAddressLb.mh_left, self.storeAddressLb.mh_bottom, 70, 30)];
    leftAllIncomeLb.font = FONT(15);
    leftAllIncomeLb.text = NSLocalizedString(@"zongshouru", nil);
    [self.contentView addSubview:leftAllIncomeLb];
    
    self.allIncomeLb = [[UILabel alloc] initWithFrame:CGRectMake(leftAllIncomeLb.mh_right, self.storeAddressLb.mh_bottom, 150, 30)];
    self.allIncomeLb.font = FONT(15);
    self.allIncomeLb.textColor = themeColor;
    self.allIncomeLb.text = @"￥180.50";
    [self.contentView addSubview:self.allIncomeLb];
    
    UILabel *leftstoreLb = [[UILabel alloc] initWithFrame:CGRectMake(self.storeAddressLb.mh_left, self.allIncomeLb.mh_bottom, 90, 30)];
    leftstoreLb.font = FONT(15);
    leftstoreLb.text = NSLocalizedString(@"shangjiaomendian", nil);
    [self.contentView addSubview:leftstoreLb];
    
    self.storeNameLb = [[UILabel alloc] initWithFrame:CGRectMake(leftstoreLb.mh_right, self.allIncomeLb.mh_bottom, 150, 30)];
    self.storeNameLb.font = FONT(15);
    self.storeNameLb.text = @"西湖银泰店";
    [self.contentView addSubview:self.storeNameLb];
    
    
   UIView *line = [QTTools tool_addLineWithFrame:CGRectMake(0, self.storeImgView.mh_bottom+10, SCREEN_WIDTH, 1) superView:self.contentView];
    self.actionBtn = [UIButton buttonWithType:UIButtonTypeCustom];
    self.actionBtn.frame = CGRectMake(SCREEN_WIDTH - 100, line.mh_bottom+10, 85, 30);
    [self.contentView addSubview:self.actionBtn];
    [self.actionBtn setImage:IMAGE(@"ljsj") forState:UIControlStateNormal];
    
    
}

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
